import { EditOutlined } from "@ant-design/icons"
import { Button } from "antd"

import { useLocale } from "@/locales"

const EditButton = (props: any) => {
	const { formatMessage } = useLocale()
	return (
		<Button icon={<EditOutlined />} {...props}>
			{formatMessage({ id: props.label ?? "label.edit" })}
		</Button>
	)
}

export default EditButton
